package com.zyndev.validation.entity;

import com.zyndev.tool.validation.constraints.*;

import java.util.List;

/**
 * desc :
 * author: 张瑀楠
 * email : zyndev@gmail.com
 * date  : 2017/11/30 下午11:21
 * todo  :
 */
@Valid
public class Student {

    @NotNull
    @Min(1)
    private Integer id;

    @Size(min = 20)
    @NotNull
    private String name;

    @NotNull
    @Min(10)
    @Max(100)
    private Integer age;

    @Size
    private List<String> stringList;

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Integer getAge() {
        return age;
    }

    public void setAge(Integer age) {
        this.age = age;
    }

    public List<String> getStringList() {
        return stringList;
    }

    public void setStringList(List<String> stringList) {
        this.stringList = stringList;
    }
}
